package carRental;

public abstract class Car {
    private String num;
    private String brand;
    private double rent;

    public String getNum() {
        return num;
    }

    public void setNum(String num) {
        this.num = num;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public double getRent() {
        return rent;
    }

    public void setRent(double rent) {
        this.rent = rent;
    }

    public Car() {
    }
    public Car(String num, String brand, double rent) {
        this.num = num;
        this.brand = brand;
        this.rent = rent;
    }

    @Override
    public String toString() {
        return "汽车{" + "车牌号='" + num + '\'' + ", 品牌='" + brand + '\'' + ", 日租金=" + rent + '}';
    }
    public abstract double totalmoney(int days , double rent);
    public abstract boolean equals(Car car);
}